package cn.wolfcode.luowowo.mgrsite.controller;

import cn.wolfcode.luowowo.article.domain.StrategyCommend;
import cn.wolfcode.luowowo.article.service.IStrategyCommendService;
import cn.wolfcode.luowowo.common.query.QueryObject;
import com.github.pagehelper.PageInfo;
import org.apache.dubbo.config.annotation.Reference;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.ModelAttribute;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
@RequestMapping("strategyCommend")
public class StrategCommendController {
    @Reference
    private IStrategyCommendService strategyCommendService;

    @RequestMapping("list")
   public String list(@ModelAttribute("qo")QueryObject qo,Model model){
        PageInfo<StrategyCommend> pageInfo = strategyCommendService.queryForList(qo);
        model.addAttribute("pageInfo",pageInfo);
        return "strategyCommend/list";
    }
}
